package com.extension.company.contract.home;

import com.extension.company.common.mvp.IModel;
import com.extension.company.common.mvp.IView;
import com.extension.company.model.entity.GoodsInfoDetail2;
import com.extension.company.model.entity.GoodsInforBean;

import java.util.List;

/**
 * 作者：zwk
 * 时间：on 2019/2/19 13:53
 * 功能：商品详情fragment的mvp 联系
 */
public interface GoodInfoFragmentContract {

	interface Mode extends IModel {
		void goodsAndCommitRequest(int goodsId, M2P m2P);

		void addCart(String goodId, String goodsNum, String goodSkuId, addM2P callback);

	}

	interface View extends IView {
		void goodsCommit(); // 商品评论

		void goodsInfo(GoodsInforBean.DataBean.GoodsInfoBean bean); // 商品的信息

		void banner(List<String> urlList);// 轮播图

		void p2v(GoodsInfoDetail2 bean2);

		void addCarMsgCallBack(String msg); // 添加购物车返回信息

		void secondFloorFragment(); // 详情二楼的回调
	}

	interface M2P { // Model callback p
		void m2pSuccess(GoodsInforBean bean); // 成功的回调

		void m2pFaile();   // 失败的回调

		void m2p(GoodsInfoDetail2 bean2);
	}

	interface addM2P {
		void addGoods2Cart(String msg);
	}
}
